package com.zhisheng.day10_tlias.utils;
/*
    可以通过这个工具类,让多线程的情况下,安全的存值和取值
 */
public class MyThreadLocaUtils {

    private static ThreadLocal local = new ThreadLocal();

    public static <T> void set(T t){
        local.set(t);
    }

    public static <T> T get(Class<T> tClass){
        return (T)(local.get());
    }
}
